package org.example.service.Impl;


import org.example.bean.Product;
import org.example.mapper.ProductDao;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ProductServise {
    @Autowired
    ProductDao productDao;
    public List<Product> getAll(){
        return productDao.list();
    };
    public void del(int id){
        productDao.del(id);
    };
    public void add(Product product){productDao.add(product);}
    public void update(Product product){productDao.update(product);}
}
